<SCRIPT type="text/javascript">
   var company_name = "D-Link";
   var copyright = "";
   var hostname = "dsa6100.ntue.edu.tw";
   var creditcardenable = "";
   var payment_gateway_type = "Disabled";
   var Instant_Account = "No";
   var remain = "1";
   var preOpenURL = true;
   var wg_num = 0;
   var wg_url = new Array();
   var wg_header = new Array();
   var wg_description = new Array();
   var pop_win = "Enabled";
   var roomInfo = new Array();
   </SCRIPT>

<html>
<head>
<meta http-equiv="Pragma" content="no-cache">
 <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
 <meta http-equiv="Cache-Control" content="no-cache">
 <link href="../include/style.css" rel="stylesheet" type="text/css">
 <link href="../include/template_css.shtml" rel="stylesheet" type="text/css">
<script language="JavaScript" src="../include/utility.shtml"></script>
<title>Login</title>

<style type="text/css">
.style1 {font-family: "Courier New", Courier, mono; font-size: 18px; font-weight: bold;}
.style6 {font-family: "Courier New", Courier, mono; font-size: 14px; font-weight: bold;}
.style11 {font-family: "Courier New", Courier, mono; font-size: 12px;}
.style12 {color: #666666; font-size: 12px; font-family: "Courier New", Courier, mono;}
</style>

<script language="javascript1.2">
var pham = document.cookie;
var disableButton=false;

function getCookie(name)
{
name += "="; // append '=' to name string
var i = 0; // index of first name=value pair
while (i < pham.length) {
var offset = i + name.length; // end of section to compare with name string
if (pham.substring(i, offset) == name) { // if string matches
var endstr = pham.indexOf(";", offset); // locate end of name=value pair
if (endstr == -1) endstr = pham.length;
return unescape(pham.substring(offset, endstr));
// return cookie value section
}
i = pham.indexOf(" ", i) + 1; // move i to next name=value pair
if (i == 0) break; // no more values in cookie string
}
return null; // cookie not found
}

function CodeCookie(str)
{
var strRtn="";

for (var i=str.length-1;i>=0;i--)
{
       strRtn+=str.charCodeAt(i);
       if (i) strRtn+="a";
}
return strRtn;
}

function DecodeCookie(str)
{
var strArr;
var strRtn="";

strArr=str.split("a");

for(var i=strArr.length-1;i>=0;i--)
strRtn+=String.fromCharCode(eval(strArr[i]));

return strRtn;

}

               function MM_swapImgRestore() { //v3.0
               var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
               }

               function MM_preloadImages() { //v3.0
               var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
               var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
               if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
               }

               function MM_findObj(n, d) { //v4.01
               var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
               d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
               if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
               for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
               if(!x && d.getElementById) x=d.getElementById(n); return x;
               }

               function MM_swapImage() { //v3.0
               var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
               if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
               }


               function init(form)
               {
                       id   = base64_decode(getCookie("rememberme_username"));
                       pwrd = base64_decode(getCookie("password"));
                       remem = getCookie("rememberme");
                       if(remem!="" && remem != null && id!="" && id!=null)
                       {
                               form.myusername.value = id;
                       }
                       if(remem!="" && remem != null && pwrd !="" && pwrd != null)
                       {
                               form.mypassword.value = pwrd;
                       }
                       form.rememberme.checked = false;
                       if(remem!="" && remem != null)
                       {
                                   form.rememberme.checked = true;
                       }
                       form.myusername.focus();
               }

               function Form_Submit(form)
               {
                       if (Before_Submit(form)) {
                           if (window.preOpenURL == true && pop_win !="None") {
                               var session_c = getCookie("session");
                               var ReturnUrl_c = getCookie("ReturnUrl");
                               var url = 'http://'+hostname+'/no_cookie_loginpages/'+'entry_portal.shtml?uname='+form.myusername.value+'&session='+session_c+'&ReturnUrl='+ReturnUrl_c;
                               var win = window.open(url);
                               if (win) win.focus();
                           }
                           form.submit();
                       }
               }
               function Reminder_Submit(form)
               {
                       if (Before_Submit(form)) {
                               Reminder.myusername.value = form.myusername.value;
                               Reminder.mypassword.value = form.mypassword.value;
                               Reminder.submit();
                       }
               }

               function Before_Submit(form)
               {
                       var check_name = new RegExp(/.*@.*@.*/);
                       var check_comma = new RegExp(/.*,.*/);
                       if(form.myusername.value == "")
                       {
                               alert("請輸入帳號。");
                               form.myusername.focus();
                               form.myusername.select();
                               disableButton=false;

                               return false;
                       }
                       if (check_name.test(form.myusername.value)){
                               alert("帳號只允許一個 \"@\" 符號，請重新輸入！");
                               form.myusername.focus();
                               form.myusername.select();
                               disableButton=false;
                               return false;
                       }
                       if (check_comma.test(form.myusername.value)){
                               alert("帳號不接受 \",\" 符號，請重新輸入！");
                               form.myusername.focus();
                               form.myusername.select();
                               disableButton=false;
                               return false;
                       }
                       if(form.mypassword.value == "")
                       {
                               alert("請輸入密碼");
                               form.mypassword.focus();
                               form.mypassword.select();
                               disableButton=false;

                               return false;
                       }

                       if(disableButton==true)
                       {
                               alert("正在登入中，請勿重覆點擊登入按鍵，並請稍待一下...");
                               return false;
                       }
                       else
                       {
                               disableButton=true;
                               return true;
                       }
                       return true;
               }
               function reminder_onclick(form)
               {
                       Reminder.myusername.value = form.myusername.value;
                       Reminder.mypassword.value = form.mypassword.value;
                       Reminder.submit();
               }
               function cancel_onclick(form)
               {
                       form.reset();
               }

       </script>
</head>

<body onload="init(Enter);" bgproperties="fixed" style="background-image: url(images1/ntue_background.jpg); background-repeat: no-repeat; background-position: center top;">

<form action="userlogin.shtml" method="post" name="Enter">


<table style="width: 746px; height: 72px;" border="0" align="center">
         <tbody>
           <tr>
             <td style="background-repeat: no-repeat; height: 72px; width: 746px;" bgproperties="fixed" background="images1/ntue_banner.jpg" align="right"><div style="color: white; font-weight: bold;" align="right"><font size="+1">國立台北教育大學 Wi-Fi 無線網路 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </font></div></td>
           </tr>
         </tbody>
</table>



<br>

<table align="center" bgcolor="#FFFFFF" border="1" bordercolor="#000099" cellpadding="0" cellspacing="0" height="180" width="480">
         <tbody>
           <tr>
             <td>

<table align="center" border="0" width="480">
               <tbody>
                 <tr>
                   <td>&nbsp;</td>

                 </tr>
               </tbody>
</table>

<table align="center" border="0" width="480">
<tbody>
<tr>
<td>
<div align="center"><font color="#FF0000" size="-1"><span class="style6"><font><b>歡迎使用無線網路，請利用以下兩種方式登入: </b></font></span>
</font></div>

</td>
</tr>
<tr>
<td><font size="-1">&nbsp; &nbsp; &nbsp;1. 學號/身份證字號 (字母大寫)，例: 帳號：109801001　密碼：A123456789</font></td>
</tr>
</tbody>
</table>

<table align="center" border="0" width="480">
<tbody>
 <tr>
<td><font size="-1">&nbsp; &nbsp; &nbsp;2. 信箱帳號/密碼，以此方式第一次登入請點選「<b><a href=http://cc.ntue.edu.tw/modules/tadnews/index.php?nsn=14>使用說明</a></b>」</font></td>
</tr>
</tbody>
</table>

<br>

<table align="center" border="0" width="480">
               <tbody>

                 <tr>
                   <td width="120"><br>
                   </td>
                   <td style="text-align: right;" valign="middle" width="82"><font size="-1">帳 號：</font></td>
                   <td valign="middle" width="202"> <input name="myusername" size="25" type="text"> </td>
                   <td width="68"><br>
                   </td>

                 </tr>
                 <tr>
                   <td><br>
                   </td>
                   <td style="text-align: right;" valign="middle" width="82"><font size="-1">密 碼：</font></td>
                   <td valign="middle" width="202"> <input name="mypassword" size="25" type="password"> </td>
                   <td><br>

                   </td>
                 </tr>
                   <tr>
                   <td><br>
                   </td>
                   <td align="right" valign="middle"><input name="rememberme" type="checkbox"> </td>
                   <td align="left" valign="middle"><font size="-1">記住帳號密碼</font>
                   <td><br>

                   </td>
                 </tr>
               </tbody>
</table>


<br>

<table align="center" border="0" width="480">
<tbody>
<tr>
<td align="center">
<input name="button_submit" onclick="javascript:Form_Submit(Enter);" value="登 入" type="button">
<input name="button_clear" onclick="cancel_onclick(Enter)" value="清 除" type="button"> </td>
</tr>

</tbody>
</table>

<br>

</td>
</tr>
</tbody>
</table>


<table align="center" border="0" cellpadding="0" cellspacing="0" width="500">

   <tbody>
     <tr>
       <td><br>
       </td>
     </tr>
     <tr style="font-weight: bold;">
       <td style="text-align: center;"><font color="#333333" size="-1">國立台北教育大學計算機與網路中心</font></td>
     </tr>

     <tr align="center">
       <td><font style="font-weight: bold;" color="#333333" size="-1">聯絡信箱: cc@tea.ntue.edu.tw</font><font size="-1"><span style="font-weight: bold;"> </span><br>
       </font></td>
     </tr>
     <tr style="font-weight: bold;">
       <td style="text-align: center;"><font color="#333333" size="-1">日間分機：2902　夜間分機：3352</font></td>
     </tr>

   </tbody>
</table>
</form>

</body>
</html>